package com.stx.design.builder;

public class BuilderTest {
	public static void Test(){
		System.out.print("=========Begin BuilderTest=========\r\n");
		
		System.out.print("Begin Mobile...\r\n");
		showBike(new MobileBuilder());
		System.out.print("End Mobile...\r\n");
		System.out.print("Begin ofo...\r\n");
		showBike(new OfoBuilder());
		System.out.print("End ofo...\r\n");
		System.out.print("=========End BuilderTest=========\r\n");
	}
	
	
	private static void showBike(Builder builder){
		Director director = new Director(builder);
		Bike bike = director.construct();
		bike.getFrame().frame();
		bike.getSeat().seat();
		bike.getTire().tire();
	}
	
}
